﻿using Wei8808Cms.Model;
using Wei8808Cms.Utility;

namespace Wei8808Cms.DAL
{
    public class WebSetDAL
    {
        private static readonly object LockHelper = new object();

        public WebSet LoadConfig(string configFilePath)
        {
            return (WebSet)SerializationHelper.Load(typeof(WebSet), configFilePath);
        }
        public WebSet SaveConifg(WebSet mode, string configFilePath)
        {
            lock (LockHelper)
            {
                SerializationHelper.Save(mode, configFilePath);
            }
            return mode;
        }
    }
}
